Flower Classifier


Classifying Flowers with Image data

Data for this analysis comes from Maria-Elena Nilsback and Andrew Zisserman's 2008 study, “Automated Flower Classification over a Large Number of Classes”.

The dataset includes 8,192 images of 102 classes of flowers.

I begin by selecting three flower types and creating a three class classifier. My model classifies very well, with an AUC of .99 and accuracy of .98.

I then create a classifier with all 102 flower classes. This classifier has a high AUC score as well of .97 and accuracy of .57. I plan to work to improve these metrics further, optimizing my model to allow for more complexity and training time.


Three class classifier

Set-up training, test, validation datasets

Only need to complete this section once

Create ImageDataGenerator

Visualizing Images

Sample of training images

Modeling

Squeezenet model

Squeezenet model with batch normalization


Evaluation

The best performing model was the Squeezenet model achieving an AUC of 0.9883659 and accuracy of 0.97869575 on test data.


Classifying all flower categories (102 classes)

Set-up train, validation, test data for entire dataset of flowers

Only complete this section once

Create class folder for train/validation/test images

Prepare ImageDataGenerator

Visualizing Images

Sample of training images

Modeling

Squeezenet model

This model as a high AUC of .95, but the accuracy is lower than the three class classifier at .57.

Using the full dataset is much larger, and training time takes much longer. Using Google Colab, my session crashed several times mid-training for other models I had tried testing. I will continue to optimize and train this model to achieve better performance.